package com.conn;

public class LocalSimpleStore implements Store {
    public boolean storeRegisterInfo(String key, RegisterInfo ri) {
        System.out.println("store register info to local file(simple store)");
        if (!FileHelper.genFile(key))
            return false;
        
        FileHelper.objectWrite(key, ri);

//        ri = (RegisterInfo)FileHelper.objectRead(key);
//        System.out.println("read object");
//        System.out.println("name: "+ri.name);
//        System.out.println("sex: "+ri.sex);
//        System.out.println("birthday: "+ri.birthday);
//        System.out.println("phone: "+ri.phone);
//        System.out.println("country: "+ri.country);
//        System.out.println("home: "+ri.home);
//        System.out.println("username: "+ri.username);
        return true;
    }
}
